package model

import "time"

type QuestionAnswerModel struct {
	Id                 int       `json:"id" gorm:"type:int(11) auto_increment; NOT NULL; primary_key"`
	QrBizId            string    `json:"qr_biz_id" gorm:"type:varchar(255); COMMENT:'问答 id'"`
	TypeClassifyId     int       `json:"type_classify_id" gorm:"type:int(11); COMMENT:'类型分类 id'"`
	BusinessClassifyId int       `json:"business_classify_id" gorm:"type:int(11); COMMENT:'业务分类 id'"`
	Question           string    `json:"question" gorm:"type:text; COMMENT:'问题'"`
	Answer             string    `json:"answer" gorm:"type:text; COMMENT:'答案'"`
	GenerationCount    int       `json:"generation_count" gorm:"type:int(11); COMMENT:'生成次数'"`
	LastGenerationDay  time.Time `json:"last_generation_day" gorm:"type:date; COMMENT:'生成日期'"`
	CreatedAt          time.Time `json:"created_at" gorm:"type:timestamp"`
	UpdatedAt          time.Time `json:"updated_at" gorm:"type:timestamp"`
}

func (QuestionAnswerModel) TableName() string {
	return "question_answer"
}
